#pragma once

namespace ns_err
{
    typedef int com_t;

    enum CompileErrCode
    {
        OPEN_FILE_FAILED = 1, // 文件打开失败
        EXCEL_FAILED = 2,     // 替换程序失败
        FORK_FAILED = 3,      // 创建子进程失败
    };

    enum CompileRunErrCode
    {
        CODE_EMPTY = -1,//代码为空
        WRITE_FILE_FAILED = -2,//写文件失败
        COMPILE_FAILED = -3,//编译失败
        RUN_FAILED = -4,//运行失败
        SECCOMP_FAILED = -5,//seccomp加载规则失败
        SECCOMP_KILLED = -6,//seccomp杀死进程
    };
}